@import '../../common/variables.scss';
.yun-alert {
  position: relative;
  width: 100%;
  padding: 8px 15px;
  border-radius: $border-base-radius;
  color: $color-text-default;
  font-size: $base-font-size;
  line-height: $base-line-height;
  margin-bottom: 10px;
  &.yun-alert-with-icon {
    padding: 8px 48px 8px 38px;
  }
  &.yun-alert-with-desc {
    &.yun-alert-with-icon {
      padding: 8px 16px 8px 69px;
    }
    .yun-alert-icon {
      left: 24px;
      .yun-iconfont {
        font-size: 36px;
      }
    }
    .yun-alert-desc {
      display: block;
    }
  }
}

.yun-alert-success {
  border: 1px solid $color-success-light3;
  background-color: $color-success-light6;
  .yun-alert-icon {
    color: $color-success;
  }
}

.yun-alert-info {
  border: 1px solid $color-primary-light3;
  background-color: $color-primary-light6;
  .yun-alert-icon {
    color: $color-primary;
  }
}

.yun-alert-warning {
  border: 1px solid $color-warning-light3;
  background-color: $color-warning-light6;
  .yun-alert-icon {
    color: $color-warning;
  }
}

.yun-alert-error {
  border: 1px solid $color-danger-light3;
  background-color: $color-danger-light6;
  .yun-alert-icon {
    color: $color-danger;
  }
}

.yun-alert-message {
  font-size: $base-font-size;
  color: $color-text-primary;
}
.yun-alert-with-desc .yun-alert-message {
  display: block;
  font-size: $header-font-size;
  margin-bottom: 4px;
}
.yun-alert-desc {
  display: none;
  text-align: justify;
}

.yun-alert-icon {
  top: 6px;
  left: 14px;
  position: absolute;
  .yun-iconfont {
    line-height: $base-line-height;
    font-size: 18px;
  }
}
.yun-alert-close {
  position: absolute;
  right: 10px;
  top: 8px;
  overflow: hidden;
  cursor: pointer;
  .yun-icon-close {
    color: $color-text-secondary;
    transition: color $animation-duration-base ease;
    position: relative;
    &:hover {
      color: $color-text-default;
    }
  }
}
.yun-alert-with-banner {
  border-radius: 0;
}
